package servlets;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import bean.Articles;
import bean.SearchArt;


@SuppressWarnings("serial")
public class JoinServlet extends HttpServlet{
	protected void doGet(HttpServletRequest req, HttpServletResponse resp)
			throws ServletException, IOException {
		long id = Long.parseLong(req.getParameter("id"));
		SearchArt sr = new SearchArt();
		Articles art = sr.searchById(id);
		
		req.setAttribute("oneArt", art);
		req.getRequestDispatcher("./group/join.jsp").forward(req, resp);		
		
	}
}
